class ComicModel {
  int Id;

  String Title;

  String Thumb;

  String Intro;

  List<dynamic> SwiperList = [];

  List<dynamic> Tags = [];

  int IsFavourite = 0;

  ComicModel(
    this.Id,
    this.Title,
    this.Thumb, {
    this.Intro = "",
    this.SwiperList = const [],
    this.Tags = const [],
    this.IsFavourite = 0,
  });

  ComicModel.formJson(Map<String, dynamic> json)
      : Id = json["Id"],
        Thumb = json["Thumb"],
        this.Title = json["Title"],
        this.Intro = json["Intro"] ?? "",
        this.SwiperList = json["Swiper"] ?? [],
        this.Tags = json["Tags"] ?? [],
        this.IsFavourite = json["IsFavourite"] ?? 0;

  Map<String, dynamic> toJson() => <String, dynamic>{
        "Id": this.Id,
        "Thumb": this.Thumb,
        "Title": this.Title,
        "Swiper": this.SwiperList,
        "Intro": this.Intro,
        "Tags": this.Tags,
        "IsFavourite": this.IsFavourite,
      };
}
